package com.example.springinitialization.pojo.dto.userDto;

import com.baomidou.mybatisplus.annotation.TableField;
import lombok.Data;

import javax.validation.constraints.Min;
import javax.validation.constraints.NotNull;
import javax.validation.constraints.Size;
import java.io.Serializable;
import java.util.Date;

@Data
public class UserResisterDto implements Serializable {
    /**
     * 用户名称
     */
    @NotNull(message = "输入参数不能为空")
    @Size(min = 6, max = 12, message = "必须输入6-12位的用户名称")
    private String username;

    /**
     * 用户密码
     */
    @NotNull(message = "输入参数不能为空")
    @Size(min = 6, max = 12, message = "必须输入6-12位的用户密码")
    private String userPassword;

    /**
     * 用户确认密码
     */
    @NotNull(message = "输入参数不能为空")
    @Size(min = 6, max = 12, message = "必须输入6-12位的用户密码")
    private String rePassword;

    /**
     * 生日
     */
    private Date birthday;

    /**
     * 性别
     */
    private String sex;

    /**
     * 地址
     */
    private String address;

    @TableField(exist = false)
    private static final long serialVersionUID = 1L;
}
